#ifndef DW_GRAPHICS_RENDER_TARGET_H
#	define DW_GRAPHICS_RENDER_TARGET_H

#include "graphics/color.h"

namespace dw {
	namespace graphics {

class RenderTarget
{
public : //! @name Types definitions
	//! @{
	enum ClearModes
	{
		NONE = 0,
		COLOR = (1 << 0),
		DEPTH = (1 << 1),
		STENCIL = (1 << 2),
		COLOR_AND_DEPTH = COLOR | DEPTH,
		ALL = COLOR | DEPTH | STENCIL,
		DEFAULT = COLOR_AND_DEPTH
	};
	//! @}

public : //! @ Constants
	//! @{
	static const dw::uint32 DefaultClearMode;
	static const Colorf DefaultClearColor;
	static const dw::float32 DefaultClearDepth;
	static const dw::int32 DefaultClearStencil;
	//! @}

public : //! @name Construction & Destruction
	//! @{
	RenderTarget();
	virtual ~RenderTarget();
	//! @}

public : //! @ Setup
	//! @{
	void setClearMode(dw::uint32 mode);
	void setClearColor(const Colorf& color);
	void setClearDepth(dw::float32 depth);
	void setClearStencil(dw::int32 stencil);
	//! @}

public : //! @name State
	//! @{
	dw::uint32 getClearMode() const ;
	const Colorf& getClearColor() const ;
	dw::float32 getClearDepth() const ;
	dw::int32 getClearStencil() const ;

	virtual bool isValid() const = 0;
	//! @}

private :
	dw::int32 m_clearMode;
	Colorf m_clearColor;
	dw::float32 m_clearDepth;
	dw::int32 m_clearStencil;
};

	} // namespace graphics
} // namespace dw

#include "graphics/rendertarget.inl"

#endif // !DW_GRAPHICS_RENDER_TARGET_H
